package com.infore.siteManagement.entity.equipment;

import java.io.Serializable;
import javax.persistence.*;

import org.hibernate.annotations.GenericGenerator;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;

/**
 * The persistent class for the EQUIP_AND_REAGENT database table. 仪器模板和试剂中间表
 */
@Entity
@Table(name = "EQUIP_AND_REAGENT")
@NamedQuery(name = "EquipAndReagent.findAll", query = "SELECT e FROM EquipAndReagent e")
public class EquipAndReagent implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@Column(name = "ID")
	@GeneratedValue(generator = "uuidGenerator")
	@GenericGenerator(name = "uuidGenerator", strategy = "uuid") // UUID生成策略
	private String id;

	@Column(name = "EQUIP_MODEL_ID")
	private String equipModelId;

	@Column(name = "REAGENT_ID")
	private String reagentId;

	@Column(name = "DANGER_SURPLUS")
	private String dangerSurplus;

	@ManyToOne
	@JoinColumn(name = "REAGENT_ID", referencedColumnName = "ID", insertable = false, updatable = false)
	@NotFound(action = NotFoundAction.IGNORE)
	private EquipReagent equipReagent;

	public EquipAndReagent() {
	}

	public EquipReagent getEquipReagent() {
		return equipReagent;
	}

	public void setEquipReagent(EquipReagent equipReagent) {
		this.equipReagent = equipReagent;
	}

	public String getDangerSurplus() {
		return dangerSurplus;
	}

	public void setDangerSurplus(String dangerSurplus) {
		this.dangerSurplus = dangerSurplus;
	}

	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getEquipModelId() {
		return this.equipModelId;
	}

	public void setEquipModelId(String equipModelId) {
		this.equipModelId = equipModelId;
	}

	public String getReagentId() {
		return this.reagentId;
	}

	public void setReagentId(String reagentId) {
		this.reagentId = reagentId;
	}

}